﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Titan.Core
{
    public enum OperationType
    {
        SelectOne,
        InsertOne,
        UpdateOne,
        DeleteOne,

        SelectMultiple,
        UpdateMultiple,
        DeleteMultiple,

    }
    public class Operation
    {
        public Operation(object entityType, OperationType operationType, Dictionary<string, object> key)
        {
            EntityType = entityType;
            OperationType = operationType;
            Key = key;
        }
        public object EntityType { get; set; }
        public OperationType OperationType { get; set; }
        public Dictionary<string, object> Key { get; set; }


    }
    public interface IEntityOperationMonitor
    {
        void OnOperate(IDbSession session, Operation operation);
    }
}
